
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Time    : 2018/2/1 14:41
# @Author  : readerror
# @Site    : 
# @File    : POSTagging.py
# @Software: PyCharm

__author__ = 'readerror'

import jieba
import jieba.posseg  # 需要另外加载一个词性标注模块
from api import utils  # 需要另外加载一个词性标注模块

string = '其实习近平买手机就是看个心情，没必要等等VS的v is dsdcsdc sds比来比去的。'
seg = jieba.posseg.cut(string)

l = []
for i in seg:
    l.append((i.word, utils.ICTCLAS[i.flag]))

print(l)
